package com.yunji.common.constant;

/**
 * 缓存的key 常量
 * 
 * @author yunji
 */
public class CacheCode
{
    private CacheCode() { }

   // public static final String LOGIN_USER_KEY = "login:user:";

    public static final String LOGIN_TOKEN_KEY = "login:user:";

    /**
     * 登录用户 redis key
     */
   // public static final String LOGIN_TOKEN_KEY = "login_tokens:";

    /**
     * 验证码 redis key
     */
    public static final String CAPTCHA_CODE_KEY = "captcha_codes:";

    /**
     * 参数管理 cache key
     */
    public static final String SYS_CONFIG_KEY = "sys_config:";

    /**
     * 字典管理 cache key
     */
    public static final String SYS_DICT_KEY = "sys_dict:";

    /**
     * 防重提交 redis key
     */
    public static final String REPEAT_SUBMIT_KEY = "repeat_submit:";

    /**
     * 限流 redis key
     */
    public static final String RATE_LIMIT_KEY = "rate_limit:";

    /**
     * 登录账户密码错误次数 redis key
     */
    public static final String PWD_ERR_CNT_KEY = "pwd_err_cnt:";

    //------------------------以下是业务相关key相同业务前缀保持一致-------------------------

    //------------------------售卖柜-------------------------
    // 小程序审核
    public static final String APP_AUDIT = "app:audit";

    //------------------------售卖柜-------------------------
    //设备开关柜redis
    public static final String CONTAINER_UNLOCK = "cabinet:unlock:";

    public static final String CONTAINER_LOCK = "cabinet:lock:";

    //订单开柜reids
    public static final String OPEN_ORDER = "cabinet:open_order:";


    //------------------------库存相关key-------------------------
    // 操作库存
    public static final String OPERATE_STOCK = "stock:";


    //------------------------短信-------------------------
    // 短信服务redis key
    public static final String SMS_KEY = "sms_login:sms_key:";
    // 短信发送次数
    public static final String SMS_SEND_COUNT = "sms_login:send_count:";

    //------------------------自增-------------------------
    //流水号自增专用
    public static final String NUM_INCREMENT = "num:increment:";
}
